package com.stores.model;

import java.util.List;

import javax.jdo.annotations.IdGeneratorStrategy;
import javax.jdo.annotations.PersistenceCapable;
import javax.jdo.annotations.Persistent;
import javax.jdo.annotations.PrimaryKey;

import com.google.appengine.api.datastore.Key;

@PersistenceCapable
public class Product {

	@PrimaryKey
	@Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY)
	private Key key;
	@Persistent
	private String name;
	@Persistent
	private String shortDescription;
	@Persistent
	private String longDescription;
	@Persistent
	private double costPrice;
	@Persistent
	private long brandId;
	@Persistent
	private List<Long> categoryIds;
	@Persistent
	private List<Long> variationIds;
	@Persistent
	private int unitsInStock;	

	public void setName(String name) {
		this.name = name;
	}

	public String getName() {
		return name;
	}

	public void setShortDescription(String shortDescription) {
		this.shortDescription = shortDescription;
	}

	public String getShortDescription() {
		return shortDescription;
	}

	public void setLongDescription(String longDescription) {
		this.longDescription = longDescription;
	}

	public String getLongDescription() {
		return longDescription;
	}

	public void setCostPrice(double costPrice) {
		this.costPrice = costPrice;
	}

	public double getCostPrice() {
		return costPrice;
	}

	public void setBrandId(long brandId) {
		this.brandId = brandId;
	}

	public long getBrandId() {
		return brandId;
	}

	public void setCategoryIds(List<Long> categoryIds) {
		this.categoryIds = categoryIds;
	}

	public List<Long> getCategoryIds() {
		return categoryIds;
	}

	public void setUnitsInStock(int unitsInStock) {
		this.unitsInStock = unitsInStock;
	}

	public int getUnitsInStock() {
		return unitsInStock;
	}

	public List<Long> getVariationIds() {
		return variationIds;
	}

	public void setVariationIds(List<Long> variationIds) {
		this.variationIds = variationIds;
	}

	public Key getKey() {
		return key;
	}

	public void setKey(Key key) {
		this.key = key;
	}
}
